package com.hjli.service.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.hjli.mapper.ArticleInfoMapper;
import com.hjli.model.ArchiveInfo;
import com.hjli.model.ArticleInfo;
import com.hjli.model.ArticleInfoStr;

@Service("articleService")
public class ArticleService implements ArticleInfoMapper{

	@Resource
	ArticleInfoMapper articleInfoMapper;
	
	@Override
	public int deleteByPrimaryKey(Integer id) {
		// TODO Auto-generated method stub
		return articleInfoMapper.deleteByPrimaryKey(id);
	}

	@Override
	public int insert(ArticleInfo record) {
		// TODO Auto-generated method stub
		return articleInfoMapper.insert(record);
	}

	@Override
	public int insertSelective(ArticleInfo record) {
		// TODO Auto-generated method stub
		return articleInfoMapper.insertSelective(record);
	}

	@Override
	public ArticleInfo selectByPrimaryKey(Integer id) {
		// TODO Auto-generated method stub
		return articleInfoMapper.selectByPrimaryKey(id);
	}

	@Override
	public int updateByPrimaryKeySelective(ArticleInfo record) {
		// TODO Auto-generated method stub
		return articleInfoMapper.updateByPrimaryKeySelective(record);
	}

	@Override
	public int updateByPrimaryKey(ArticleInfo record) {
		// TODO Auto-generated method stub
		return articleInfoMapper.updateByPrimaryKey(record);
	}

	@Override
	public List<ArticleInfo> articleInfoAll() {
		// TODO Auto-generated method stub
		return articleInfoMapper.articleInfoAll();
	}

	@Override
	public int sumPageNum() {
		// TODO Auto-generated method stub
		return articleInfoMapper.sumPageNum();
	}

	@Override
	public List<ArticleInfo> pageList(int startNum, int everyPageNum) {
		// TODO Auto-generated method stub
		return articleInfoMapper.pageList(startNum, everyPageNum);
	}

	@Override
	public ArticleInfoStr findByUrl(String url) {
		// TODO Auto-generated method stub
		return articleInfoMapper.findByUrl(url);
	}

	@Override
	public String findUrlById(int id) {
		// TODO Auto-generated method stub
		return articleInfoMapper.findUrlById(id);
	}

	@Override
	public List<ArticleInfo> findByDate(String date) {
		// TODO Auto-generated method stub
		return articleInfoMapper.findByDate(date);
	}

	@Override
	public int updateViewNum(int id) {
		// TODO Auto-generated method stub
		return articleInfoMapper.updateViewNum(id);
	}


}
